<h1>Positions</h1>
<table>
	<tr>
		<th>ID</th>
		<th>Name</th>
		<th>Department ID</th>
		<th>Availability</th>
		<th>Description</th>
		<th></th>
	</tr>

	<?php foreach ($positions as $position): ?>
	<tr>
		<td><?php echo $position['Position']['id']; ?></td>
		<td><?php echo $position['Position']['name']; ?></td>
		<td><?php echo $position['Department']['name']; ?></td>
		<?php if ($position['Position']['available'] == 1) { ?>
			<td>Yes</td>
		<?php } else { ?>
			<td>No</td>
		<?php } ?>
		<td><?php echo $position['Position']['description']; ?></td>
		<td>
			<?php echo $html->link('View', '/positions/view/'.$position['Position']['id']); ?>
			<?php echo $html->link('Edit', '/positions/edit/'.$position['Position']['id']); ?>
		</td>
	</tr>
	<?php endforeach; ?>

</table>